<div class="am-u-sm-12 widget main-w">
	<form class="am-form-inline tpl-form-border-form" action="" method="get">
		<div class="am-u-sm-12">
			<div class="am-form-group am-u-sm-3 cl-p">
				<label class="am-u-sm-4 am-form-label am-text-truncate">订单号:</label>
				<div class="am-u-sm-8 cl-p">
					<input type="text" class="am-form-field" name="order_no" placeholder="请输入订单号">
				</div>
			</div>
			<div class="am-form-group am-u-sm-3 cl-p">
				<label class="am-u-sm-4 am-form-label am-text-truncate">订单类型:</label>
				<div class="am-u-sm-8 cl-p">
					<select data-am-selected="{btnWidth: '100%', btnSize: 'sm'}">
						<option value="option1">所有订单</option>
						<option value="option2">公务订单</option>
						<option value="option3">企业订单</option>
					</select>
				</div>
			</div>
			<div class="am-form-group am-u-sm-3">
				<div class="am-u-sm-4 cl-p">
					<select style="height: 33px;">
						<option value="1">用车人</option>
						<option value="2">预定人</option>
					</select>
				</div>
				<div class="am-u-sm-8 cl-p">
					<input type="text" class="tpl-form-no-bg" name="phone" placeholder="请输入名称/电话">
				</div>
			</div>

			<div class="am-form-group am-u-sm-3" style="padding-top: 3px;">
				<button type="submit" class="am-btn am-btn-primary am-radius am-btn-sm" style="margin-top: -2px;">查询<i class="am-icon-search"></i></button>
				<button type="button" id="more" class="am-btn am-btn-sm am-btn-secondary am-radius" style="margin-top: -2px;">更多查询条件</button>
			</div>
			<div id="showmore" style="display: none;">
				<div class="am-u-sm-12" style="padding:5px 0;">
					<div class="am-u-sm-3 cl-p">
						<label class="am-u-sm-4 am-form-label am-text-truncate ">用车时间:</label>
						<div class="am-u-sm-8 cl-p">
							<div class="am-u-sm-6 cl-p">
								<input type="text" class="am-form-field tpl-form-no-bg" placeholder="用车日期起始" data-am-datepicker="" readonly="">
							</div>
							<div class="am-u-sm-6 cl-p">
								<input type="text" class="am-form-field tpl-form-no-bg" placeholder="用车日期结束" data-am-datepicker="" readonly="">
							</div>
						</div>
					</div>
					<div class="am-u-sm-3 cl-p">
						<label class="am-u-sm-4 am-form-label am-text-truncate ">申请时间:</label>
						<div class="am-u-sm-8 cl-p">
							<div class="am-u-sm-6 cl-p">
								<input type="text" class="am-form-field tpl-form-no-bg" placeholder="申请日期起始" data-am-datepicker="" readonly="">
							</div>
							<div class="am-u-sm-6 cl-p">
								<input type="text" class="am-form-field tpl-form-no-bg" placeholder="申请日期结束" data-am-datepicker="" readonly="">
							</div>
						</div>
					</div>
					<div class="am-u-sm-6 cl-p">&nbsp;</div>
				</div>
			</div>

		</div>

	</form>
	<div style="padding: 10px;" class="am-u-sm-12">
		<ul class="am-tabs-nav am-nav am-nav-tabs">
			{if {:input('param.order_state')}
			<li class={:input( 'param.order_state')==0? 'am-active': " "}>
				<a href="{:url('check',['order_state'=>0])}">全部</a>
			</li>
			{else/}
			<li class='am-active'>
				<a href="{:url('check',['order_state'=>0])}">全部</a>
			</li>
			{/if}

			<li class={:input( 'param.order_state')==1? 'am-active': " "}>
				<a href="{:url('check',['order_state'=>1])}">待审核</a>
			</li>
			<li class={:input( 'param.order_state')==2? 'am-active': " "}>
				<a href="{:url('check',['order_state'=>2])}">已批准</a>
			</li>
			<li class={:input( 'param.order_state')==3? 'am-active': " "}>
				<a href="{:url('check',['order_state'=>3])}">已拒绝</a>
			</li>

		</ul>
		<div style="padding: 10px;" class="am-u-sm-12">
			<div><button style="float: right;" type="button" class="am-btn am-btn-default am-radius am-btn-xs" style="margin-top: -2px;">导出文件</button></div>
			<table width="100%" class="am-table am-table-compact am-table-bordered am-table-radius am-table-striped tpl-table-black am-text-nowrap">
				<thead>
					<tr>
						<th>订单号</th>
						<th>申请时间</th>
						<th>开始时间(不选择默认即时)</th>
						<th>订单类型</th>
						<th>申请人</th>
						<th>审核人</th>
						<th>出发地</th>
						<th>目的地</th>
						<th>用车类型</th>
						<th>用车说明</th>
						<th>订单状态</th>
						<th>操作</th>
					</tr>
				</thead>
				<tbody>
					{foreach $list as $key => $item}
					<tr class="gradeX">
						<td>{$item.order_no}</td>
						<td>{$item.apply_time}</td>
						<td>{$item.order_time}</td>
						<td>{$item.order_type}</td>
						<td>{$item.orderer}</td>
						<td>{$item.approval}</td>
						<td>{$item.departure}</td>
						<td>{$item.destination}</td>
						<td>{$item.use_type}</td>
						<td>{$item.use_explain}</td>
						<td>{$item.order_state}</td>
						<td>
							<div class="tpl-table-black-operation">
								{if $item.order_state==1}
								<a href="javascript:;">
									<i class="am-icon-pencil"></i> 同意
								</a>
								<a href="javascript:;" class="tpl-table-black-operation-del">
									<i class="am-icon-pencil"></i> 拒绝
								</a>
								<a href="javascript:;" class="tpl-table-black-operation-del">
									<i class="am-icon-trash"></i> 撤销
								</a>
								{elseif $item.order_state==2||$item.order_state==3/}
								<a href="javascript:;" class="tpl-table-black-operation-del">
									<i class="am-icon-trash"></i> 撤销
								</a>
								{elseif $item.order_state==4/}
								<a href="{:url('dispatch',['order_id'=>$item.order_id])}">
									<i class="am-icon-pencil"></i> 派车
								</a>
								<a href="javascript:;" class="tpl-table-black-operation-del delete-list" data-method="delete">
									<i class="am-icon-pencil"></i> 取消
								</a>
								{else/}
								<a class="showmap" data-method="showmap" href="javascript:;">
									<i class="am-icon-map"></i> 轨迹
								</a>
								<a href="javascript:;" class="tpl-table-black-operation-del delete-list" data-method="delete">
									<i class="am-icon-pencil"></i> 删除
								</a>
								{/if}
							</div>
						</td>
					</tr>
					{/foreach}

				</tbody>
			</table>
			<div class="am-u-lg-12 am-cf">

				<div class="am-fr">
					{$pager}
				</div>
			</div>
		</div>
	</div>

</div>